.scroll-y {
  overflow-y: scroll !important;
  overflow-x: hidden;
}

.active {
  color: var(--td-brand-color);
}

.layout {
  height: 100vh;
  width: 100vw;
  overflow: hidden;

  .t-layout {
    height: 100%;

    .zy-header {
      height: 56px;
    }

    .t-layout--with-sider {
      height: calc(100% - 56px);
    }

    .zy-content {
      flex: 1;
      margin: 0;
      height: 100%;
      width: 100%;
    }

    .zy-aside {
      width: 300px;
      height: 100%;
      background: var(--td-bg-color-container);
    }
  }
}

.zy-content {
  transition: padding .2s ease-in-out;

  .subject {
    width: 100%;
  }

  .subject:hover ~ .dock-show {
    display: flex;
  }

  .subject-ext {
    width: 100vw !important;
  }

  .dock-show {
    display: none;
    transition: 0.15s ease-out;
    background: rgba(0, 0, 0, .4);
    border-radius: 8px 0 0 8px;
    width: 32px;
    height: 84px;
    position: absolute;
    top: 50%;
    right: 0;
    transform: translateY(-50%);
    flex-direction: column;
    justify-content: center;
    align-items: center;
    z-index: 95;
    cursor: pointer;
    &:hover {
      display: flex;
      background: rgba(0, 0, 0, .5);
    }
    .btn-icon {
      width: 24px;
      height: 24px;
      color: #fbfbfb;
    }
  }
}

.container-aside {
  height: calc(100% - 20px);
  // overflow: hidden;
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin: 10px;

  .tvg-block {
    width: 100%;
    word-break: break-all;
    display: flex;
    flex-direction: column;
    gap: 6px;

    .title-album {
      width: 100%;
      display: flex;
      align-items: flex-end;

      .title-text {
        max-width: 80%;
        font-size: 24px;
        min-height: 32px;
        line-height: 32px;
        font-weight: 500;
        color: var(--td-text-color-primary);
      }

      .title-desc {
        display: inline;
        align-items: center;
        margin-left: 9px;
        font-size: 12px;
        cursor: pointer;
      }
    }

    .hot-block {
      display: flex;
      flex-direction: row;
      align-items: center;
      font-size: 12px;
      height: 12px;
      line-height: 12px;
      overflow: visible;
      position: relative;
      width: inherit;

      .rate {
        color: var(--td-brand-color);
        display: flex;
      }
    }

    .function {
      width: 100%;
      display: flex;
      flex-direction: row;
      justify-content: space-evenly;
      align-items: center;
      font-size: 14px;
      height: 40px;
      position: relative;
      box-shadow: 0 2px 8px 0 rgba(0, 0, 0, 0.08);
      background-image: linear-gradient(hsla(0, 0%, 100%, 0.04), hsla(0, 0%, 100%, 0.06));
      border-radius: var(--td-radius-default);

      .func-item {
        align-items: center;
        display: flex;
        flex: 1 1;
        height: 40px;
        justify-content: center;
        overflow: hidden;
        position: relative;
        cursor: pointer;
        color: var(--td-text-color-secondary);

        &:hover {
          color: var(--td-text-color-primary);
        }

        .tip {
          vertical-align: top;
          line-height: 25px;
          text-align: center;
          margin-left: 4px;
        }
      }

      .more {
        flex-grow: 0;
        min-width: 40px;
        width: 40px;

        .t-button--variant-text {
          color: var(--td-text-color-secondary);
          --ripple-color: transparent;
          &:hover {
            border-color: transparent;
            background-color: transparent;
            color: var(--td-text-color-primary);
          }
        }
      }

      .dot {
        height: 24px;
        width: 1px;
        border-right: 1px solid;
        border-image-source: var(--td-bg-dot);
        border-image-slice: 1;
      }
    }
  }

  .anthology-contents {
    position: relative;
    height: 100%;
    flex: 1;

    .box-anthology-header {
      font-size: 16px;
      line-height: 18px;
      display: flex;
      justify-content: space-between;
      align-items: center;
      color: var(--td-text-color-primary);

      .left {
        display: flex;
        flex-direction: row;
        flex-wrap: nowrap;
        justify-content: flex-start;
        align-items: flex-end;

        .mg-left {
          margin-left: var(--td-comp-margin-xs);
        }

        .box-anthology-title {
          white-space: nowrap;
          position: relative;
          font-size: 16px;
          line-height: 25px;
          font-weight: 500;
        }

        .box-anthology-analyze,
        .box-anthology-line {
          :deep(.t-button) {
            padding: 0;
          }

          :deep(.t-button:not(.t-is-disabled):not(.t-button--ghost)) {
            --ripple-color: transparent;
          }

          :deep(.t-button--variant-text) {
            color: var(--td-text-color-secondary);

            .t-button__suffix {
              margin-left: var(--td-comp-margin-xxs);
            }

            .t-button__text {
              &:before {
                content: '';
                width: 1px;
                margin: 0 var(--td-comp-margin-xs);
                background: linear-gradient(180deg, transparent, var(--td-border-level-1-color), transparent);
              }
            }

            &:hover,
            &:focus-visible {
              background-color: transparent !important;
              border-color: transparent !important;
              color: var(--td-brand-color);
            }
          }
        }
      }

      .right {
        .box-anthology-reverse-order {
          cursor: pointer;
        }
      }
    }

    .drive-listbox {
      height: calc(100% - 25px);

      .contents-wrap {
        // height: calc(100% - 25px);
      }
    }

    .iptv-listbox {
      height: 100%;

      .t-tabs__content {
        height: calc(100% - var(--td-comp-size-xl));
        width: 100%;

        .t-tab-panel {
          height: 100%;
          width: 100%;

          .contents-wrap {
            height: 100%;
          }

          .channel-wrap {
            height: calc(100% - 32px);

            .content {
              padding: 0;
            }
          }
        }
      }
    }

    .t-tabs__nav-item.t-size-m {
      height: var(--td-comp-size-xl);
      line-height: var(--td-comp-size-xl);
    }

    .listbox {

      .nav {
        // margin-top: 6px;
      }

      .tag-container {
        display: flex;
        flex-wrap: wrap;
        margin-top: 6px;

        .mainVideo-num {
          position: relative;
          width: 41px;
          font-size: 18px;
          height: 41px;
          line-height: 41px;
          border-radius: 8px;
          text-align: center;
          cursor: pointer;
          margin-bottom: 4px;
          margin-right: 4px;
          box-shadow: 0 2px 8px 0 rgba(0, 0, 0, 0.08);

          &:hover {
            background-image: linear-gradient(var(--td-brand-color-2), var(--td-brand-color-3));
          }

          &:before {
            content: '';
            display: block;
            position: absolute;
            top: 1px;
            left: 1px;
            right: 1px;
            bottom: 1px;
            border-radius: 8px;
            background-color: var(--td-bg-container);
            z-index: 2;
          }

          .mainVideo_inner {
            position: absolute;
            top: 1px;
            left: 1px;
            right: 1px;
            bottom: 1px;
            border-radius: 8px;
            z-index: 3;
            overflow: hidden;
            background-image: linear-gradient(hsla(0, 0%, 100%, 0.04), hsla(0, 0%, 100%, 0.06));

            .playing {
              display: none;
              min-width: 10px;
              height: 8px;
              background: url(@/assets/player/playon-green.gif) no-repeat;
            }
          }
        }

        .mainVideo-selected {
          color: var(--td-brand-color);
          background-image: linear-gradient(hsla(0, 0%, 100%, 0.1), hsla(0, 0%, 100%, 0.06));
          .playing {
            display: inline-block !important;
            position: absolute;
            left: 6px;
            bottom: 6px;
          }
        }
      }
    }

    .recommend {
      .component-title {
        font-size: 16px;
        line-height: 25px;
        font-weight: 500;
        color: var(--td-text-color-primary);
      }

      .component-list {
        .videoItem-card {
          width: 100%;
          position: relative;
          z-index: 1;
          cursor: pointer;
          display: flex;
          align-items: center;
          column-gap: 4px;
          cursor: pointer;
          padding: 6px 0;

          .videoItem-left {
            position: relative;
            float: left;
            margin-right: 10px;
            font-size: 12px;
            height: 100%;
            overflow: hidden;
          }

          .videoItem-right {
            flex: 1 1;
            position: relative;
            overflow: hidden;
            display: flex;
            flex-direction: column;
            justify-content: flex-start;

            .title {
              font-size: 14px;
              line-height: 20px;
              max-height: 40px;
              overflow: hidden;
              text-overflow: ellipsis;
              word-break: break-all;
              display: -webkit-box;
              -webkit-line-clamp: 2;
              -webkit-box-orient: vertical;
              color: var(--td-text-color-primary);
            }

            .subtitle {
              margin-top: 6px;
              line-height: 14px;
              font-size: 12px;
              max-height: 40px;
              white-space: wrap;
            }
          }
        }
      }
    }
  }

  .iptv-anthology, .drive-anthology, .analyze-anthology {
    height: calc(100% - 78px - 6px);
  }

  .contents-wrap {
    height: 100%;
    width: 100%;
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 6px;

    .content {
      padding: var(--td-comp-paddingTB-s) var(--td-comp-paddingLR-m);
      cursor: pointer;

      .time-warp {
        width: 40px;
        color: #f09736;
        margin-right: 10px;
      }

      .status-wrap {
        text-align: right;

        .played {
          color: #2774f6;
        }

        .playing, .useing {
          color: #f09736;
        }

        .unplay, .unuse {
          color: var(--td-text-color-primary);
        }
      }

      .logo-wrap {
        max-width: 60px;
        margin-right: 10px;
      }

      .title-wrap {
        font-weight: bold;
        flex: 1;
      }

      .content-item {
        display: flex;
        grid-column-gap: var(--td-size-2);
        height: 38px;
        align-items: center;
        font-weight: 500;
        cursor: pointer;
        padding: var(--td-comp-paddingTB-s) var(--td-comp-paddingLR-m);


        &:hover {
          background-color: var(--td-bg-content-hover-2);
          border-radius: var(--td-radius-medium);
        }
      }
    }
  }

  .profile {
    display: flex;
    flex-direction: column;
    height: 100%;

    .side-head {
      flex-shrink: 0;
      display: flex;
      flex-direction: row;
      justify-content: space-between;
      align-items: center;

      .title {
        font-size: 16px;
        line-height: 24px;
      }

      .icon {
        cursor: pointer;
      }
    }

    .side-body {
      flex: 1;
      position: relative;
      padding: 8px 0;

      .card {
        display: flex;
        flex-direction: row;

        .cover {
          width: 84px;
          height: 112px;
          margin-right: 12px;
        }

        .content {
          flex: 1;
          padding-top: 10px;

          .name {
            font-size: 16px;
            line-height: 24px;
            overflow: hidden;
            text-overflow: ellipsis;
            display: -webkit-box;
            -webkit-line-clamp: 2;
            -webkit-box-orient: vertical;
          }

          .type {
            font-size: 14px;
            line-height: 20px;
            margin-top: 5px;
          }

          .num {
            font-size: 14px;
            line-height: 20px;
            margin-top: 5px;
          }
        }
      }

      .background {
        margin-top: 8px;
        line-height: 20px;
        font-size: 14px;
      }

      .case, .background {
        margin-top: 12px;

        .title {
          line-height: 16px;
          font-size: 14px;
          font-weight: 500;
          color: var(--td-text-color-primary);
        }
      }
    }
  }
}

@media only screen and (max-width: 640px) {
  .zy-header {
    background: linear-gradient(360deg, rgba(0, 0, 0, 0), rgba(0, 0, 0, 0.8));
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 999;
    opacity: 0;
    pointer-events: none;
    transition:
      opacity 0.15s linear 3s,
      visibility 0s linear 3s;
    &:hover {
      opacity: 1;
      pointer-events: auto;
    }

    .left {
      .open-main-win {
        background-color: transparent !important;
        color: #fbfbfb !important;
        width: auto !important;

        .tip-gotomain {
          display: none !important;
        }

        &:hover {
          background-color: transparent !important;
          color: #fbfbfb;
        }
      }
    }

    .spacer {
      color: #fbfbfb;
    }

    .right {
      color: #fbfbfb;

      .system-functions {
        background-color: transparent !important;

        .system-function {
          margin-left: 0;
          background-color: transparent !important;

          svg {
            color: #fbfbfb !important;
          }

          &:hover {
            background-color: transparent !important;
            color: #fbfbfb !important;
          }
        }

        .setting, .sponsor, .language, .system-skin {
          display: none !important;
        }
      }

      .window {
        border-radius: 0 !important;
        background-color: transparent !important;
        cursor: pointer;
        --tb-control-hover-color: transparent !important;
        --tb-control-symbol-color: #fbfbfb !important;
        --tb-control-close-symbol-color: #fbfbfb !important;

        :deep(.titlebar__window-controls) {
          .window__control {
            cursor: pointer !important;
          }

          .window__control-close:hover {
            background-color: transparent !important;
          }
        }
      }
    }
  }
  .zy-content {
    .comm-player {
      width: 100%;
      height: 100%;
    }
    .dock-show {
      display: none !important;
    }
  }
  .t-layout--with-sider {
    height: 100% !important;
    width: 100% !important;
  }
  .t-layout:hover .zy-header, .zy-header:hover {
    opacity: 1;
    pointer-events: auto;
    transition: .2s ease;
  }
  .zy-aside {
    display: none;
  }
}
